require "mysql2"

client = Mysql2::Client.new(:host=>'127.0.0.1',:username=>'root',:password=>'123456')
client.select_db "wp"
result = client.query('SELECT  `id`,  `domain`,  `url`, 256,  `title`,  `category_id`,  `crawler`,  `httpstatus`,  `size`,  `addtime`,  `updatetime`,  `visits` FROM `sitepage`.`site435` LIMIT 10;')

result.each do |row|
	p row["url"]
end